package com.rcd.manager.dao.impl;

import java.util.List;

import com.rcd.dao.IAdminDao;
import com.rcd.exception.MyException;
import com.rcd.manager.dao.IAdminManagerDao;
import com.rcd.util.Page;
import com.rcd.vo.Admin;

public class IAdminManagerDaoimpl implements IAdminManagerDao {

	private IAdminDao admindao;

	public void setAdmindao(IAdminDao admindao) {
		this.admindao = admindao;
	}

	public void addAdmin(Admin admin) throws MyException {

		this.admindao.addAdmin(admin);
	}

	public int countAdmin(Page page) throws MyException {

		this.admindao.countAdmin(page);
		return 0;
	}

	public void delAdmin(int aid) throws MyException {

		this.admindao.delAdmin(aid);

	}

	public List<Admin> findAll(Page page) throws MyException {

		this.admindao.findAll(page);
		return null;
	}

	public Admin findbyId(int aid) throws MyException {

		this.admindao.findbyId(aid);
		return null;
	}

	public boolean loginAdmin(String aname, String apass) throws MyException {

		this.admindao.loginAdmin(aname, apass);
		return false;
	}

	public void upAdmin(Admin admin) throws MyException {

		this.admindao.upAdmin(admin);

	}

}
